package org.zxp.designpattern.singleton;

/**
 * @program: effectiveJava
 * @description: 懒汉 线程不安全
 * @author: X-Pacific zhang
 * @create: 2019-08-21 21:20
 **/
public class Singleton2 {
    private static Singleton2 INSTANCE;

    private Singleton2(){}

    public static Singleton2 getInstance(){
        if(INSTANCE == null){
            INSTANCE = new Singleton2();
        }
        return INSTANCE;
    }
}
